﻿using System.Collections.Generic;
using System.ComponentModel.DataAnnotations;

namespace Colorful.Furniture.EnterpriseManagement;

/// <summary>
///  创建部门
/// </summary>
public class CreateDepartmentInputDto
{
    /// <summary>
    ///  部门名字
    /// </summary>
    [Required(ErrorMessage = "请填写部门名字")]
    public string Name { get; set; }

    /// <summary>
    ///  英文名字
    /// </summary>
    public string NameEn { get; set; }

    /// <summary>
    ///  父级编码
    /// </summary>
    public long? ParentDepartId { get; set; }
}

public class UpdateDepartmentInputDto : CreateDepartmentInputDto
{
    /// <summary>
    ///  部门id
    /// </summary>
    public long DepartId { get; set; }
}

/// <summary>
///  设置负责人
/// </summary>
public class SetLeaderInputDto
{
    /// <summary>
    ///  部门id
    /// </summary>
    public long DepartId { get; set; }

    /// <summary>
    ///  部门负责人
    /// </summary>
    [Required(ErrorMessage = "请设置部门领导人")]
    public List<string> Leaders { get; set; }
}

/// <summary>
///  拖拽
/// </summary>
public class DragDepartmentInputDto
{
    /// <summary>
    ///  拖拽节点
    /// </summary>
    public long Id { get; set; }

    /// <summary>
    ///  拖拽后的节点
    /// </summary>
    public long DraggedId { get; set; }

    /// <summary>
    ///  拖拽类型，before、after、inner
    /// </summary>
    public string DragType { get; set; }
}
    